<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>云信Web SDK API文档</title>
    
    <meta name="description" content="云信Web SDK API文档" />
    
        <meta name="keywords" content="云信Web SDK API文档" />
        <meta name="keyword" content="云信Web SDK API文档" />
    
    
    
    <meta property="og:title" content=""/>
    <meta property="og:type" content="website"/>
    <meta property="og:image" content=""/>
    
    <meta property="og:url" content=""/>
    
    <script src="scripts/prettify/prettify.js"></script>
    <script src="scripts/prettify/lang-css.js"></script>
    <script src="scripts/jquery.min.js"></script>
    <!--[if lt IE 9]>
      <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
    <![endif]-->
    <link type="text/css" rel="stylesheet" href="styles/prettify-tomorrow.css">
    <link type="text/css" rel="stylesheet" href="styles/bootstrap.min.css">
    <link type="text/css" rel="stylesheet" href="styles/jaguar.css">
    
    
    <script>
    var config = {"monospaceLinks":true,"cleverLinks":true,"default":{"outputSourceFiles":false},"jaguarjs":true,"applicationName":"云信Web SDK API文档","disqus":"","googleAnalytics":"","openGraph":{"title":"","type":"website","image":"","site_name":"","url":""},"meta":{"title":"云信Web SDK API文档","description":"云信Web SDK API文档","keyword":"云信Web SDK API文档"},"linenums":false};
    </script>
    

    
</head>
<body>
<div id="wrap" class="clearfix">
    
<div class="navigation">
    <h3 class="applicationName"><a href="index.html">云信Web SDK API文档</a></h3>

    <div class="search">
        <input id="search" type="text" class="form-control input-sm" placeholder="Search Documentations">
    </div>
    <ul class="list">
    
        <li class="item" data-name="blob">
            <span class="title">
                <a href="blob.html">blob</a>
                
                <span class="static">static</span>
                
            </span>
            <ul class="members itemMembers">
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            <span class="subtitle">Methods</span>
            
                <li data-name="blob.fromDataURL"><a href="blob.html#.fromDataURL">fromDataURL</a></li>
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="support">
            <span class="title">
                <a href="global.html#support">support</a>
                
                <span class="static">static</span>
                
            </span>
            <ul class="members itemMembers">
            
            <span class="subtitle">Members</span>
            
                <li data-name="support.db"><a href="global.html#support#.db">db</a></li>
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="util">
            <span class="title">
                <a href="global.html#util">util</a>
                
                <span class="static">static</span>
                
            </span>
            <ul class="members itemMembers">
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            <span class="subtitle">Methods</span>
            
                <li data-name="util.cutObjArray"><a href="global.html#util#.cutObjArray">cutObjArray</a></li>
            
                <li data-name="util.findObjInArray"><a href="global.html#util#.findObjInArray">findObjInArray</a></li>
            
                <li data-name="util.guid"><a href="global.html#util#.guid">guid</a></li>
            
                <li data-name="util.mergeObjArray"><a href="global.html#util#.mergeObjArray">mergeObjArray</a></li>
            
                <li data-name="util.sortObjArray"><a href="global.html#util#.sortObjArray">sortObjArray</a></li>
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="Audio">
            <span class="title">
                <a href="Audio.html">Audio</a>
                
            </span>
            <ul class="members itemMembers">
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="Chatroom">
            <span class="title">
                <a href="Chatroom.html">Chatroom</a>
                
            </span>
            <ul class="members itemMembers">
            
            <span class="subtitle">Members</span>
            
                <li data-name="Chatroom.deepAccess"><a href="Chatroom.html#.deepAccess">deepAccess</a></li>
            
                <li data-name="Chatroom.io"><a href="Chatroom.html#.io">io</a></li>
            
                <li data-name="Chatroom.naturalSort"><a href="Chatroom.html#.naturalSort">naturalSort</a></li>
            
                <li data-name="Chatroom.platform"><a href="Chatroom.html#.platform">platform</a></li>
            
                <li data-name="Chatroom.xhr"><a href="Chatroom.html#.xhr">xhr</a></li>
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            <span class="subtitle">Methods</span>
            
                <li data-name="Chatroom.getInstance"><a href="Chatroom.html#.getInstance">getInstance</a></li>
            
                <li data-name="Chatroom#audioToMp3"><a href="Chatroom.html#audioToMp3">audioToMp3</a></li>
            
                <li data-name="Chatroom#connect"><a href="Chatroom.html#connect">connect</a></li>
            
                <li data-name="Chatroom#disconnect"><a href="Chatroom.html#disconnect">disconnect</a></li>
            
                <li data-name="Chatroom#getChatroom"><a href="Chatroom.html#getChatroom">getChatroom</a></li>
            
                <li data-name="Chatroom#getChatroomMembers"><a href="Chatroom.html#getChatroomMembers">getChatroomMembers</a></li>
            
                <li data-name="Chatroom#getChatroomMembersInfo"><a href="Chatroom.html#getChatroomMembersInfo">getChatroomMembersInfo</a></li>
            
                <li data-name="Chatroom#getHistoryMsgs"><a href="Chatroom.html#getHistoryMsgs">getHistoryMsgs</a></li>
            
                <li data-name="Chatroom#kickChatroomMember"><a href="Chatroom.html#kickChatroomMember">kickChatroomMember</a></li>
            
                <li data-name="Chatroom#markChatroomBlacklist"><a href="Chatroom.html#markChatroomBlacklist">markChatroomBlacklist</a></li>
            
                <li data-name="Chatroom#markChatroomCommonMember"><a href="Chatroom.html#markChatroomCommonMember">markChatroomCommonMember</a></li>
            
                <li data-name="Chatroom#markChatroomGaglist"><a href="Chatroom.html#markChatroomGaglist">markChatroomGaglist</a></li>
            
                <li data-name="Chatroom#markChatroomManager"><a href="Chatroom.html#markChatroomManager">markChatroomManager</a></li>
            
                <li data-name="Chatroom#packFileDownloadName"><a href="Chatroom.html#packFileDownloadName">packFileDownloadName</a></li>
            
                <li data-name="Chatroom#previewFile"><a href="Chatroom.html#previewFile">previewFile</a></li>
            
                <li data-name="Chatroom#sendCustomMsg"><a href="Chatroom.html#sendCustomMsg">sendCustomMsg</a></li>
            
                <li data-name="Chatroom#sendFile"><a href="Chatroom.html#sendFile">sendFile</a></li>
            
                <li data-name="Chatroom#sendGeo"><a href="Chatroom.html#sendGeo">sendGeo</a></li>
            
                <li data-name="Chatroom#sendText"><a href="Chatroom.html#sendText">sendText</a></li>
            
                <li data-name="Chatroom#sendTipMsg"><a href="Chatroom.html#sendTipMsg">sendTipMsg</a></li>
            
                <li data-name="Chatroom#setOptions"><a href="Chatroom.html#setOptions">setOptions</a></li>
            
                <li data-name="Chatroom#updateChatroom"><a href="Chatroom.html#updateChatroom">updateChatroom</a></li>
            
                <li data-name="Chatroom#updateChatroomMemberTempMute"><a href="Chatroom.html#updateChatroomMemberTempMute">updateChatroomMemberTempMute</a></li>
            
                <li data-name="Chatroom#updateMyChatroomMemberInfo"><a href="Chatroom.html#updateMyChatroomMemberInfo">updateMyChatroomMemberInfo</a></li>
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="ChatroomInfo">
            <span class="title">
                <a href="ChatroomInfo.html">ChatroomInfo</a>
                
            </span>
            <ul class="members itemMembers">
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="ChatroomMember">
            <span class="title">
                <a href="ChatroomMember.html">ChatroomMember</a>
                
            </span>
            <ul class="members itemMembers">
            
            <span class="subtitle">Members</span>
            
                <li data-name="ChatroomMember.type"><a href="ChatroomMember.html#.type">type</a></li>
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="ChatroomMessage">
            <span class="title">
                <a href="ChatroomMessage.html">ChatroomMessage</a>
                
            </span>
            <ul class="members itemMembers">
            
            <span class="subtitle">Members</span>
            
                <li data-name="ChatroomMessage.attach.type"><a href="ChatroomMessage.html#.attach.type">attach.type</a></li>
            
                <li data-name="ChatroomMessage.type"><a href="ChatroomMessage.html#.type">type</a></li>
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="Controller">
            <span class="title">
                <a href="Controller.html">Controller</a>
                
            </span>
            <ul class="members itemMembers">
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            <span class="subtitle">Methods</span>
            
                <li data-name="Controller.install"><a href="Controller.html#.install">install</a></li>
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="File">
            <span class="title">
                <a href="File.html">File</a>
                
            </span>
            <ul class="members itemMembers">
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="Friend">
            <span class="title">
                <a href="Friend.html">Friend</a>
                
            </span>
            <ul class="members itemMembers">
            
            <span class="subtitle">Members</span>
            
                <li data-name="Friend.requestType"><a href="Friend.html#.requestType">requestType</a></li>
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="Geo">
            <span class="title">
                <a href="Geo.html">Geo</a>
                
            </span>
            <ul class="members itemMembers">
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="Image">
            <span class="title">
                <a href="Image.html">Image</a>
                
            </span>
            <ul class="members itemMembers">
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="IMMessage">
            <span class="title">
                <a href="IMMessage.html">IMMessage</a>
                
            </span>
            <ul class="members itemMembers">
            
            <span class="subtitle">Members</span>
            
                <li data-name="IMMessage.attach.type"><a href="IMMessage.html#.attach.type">attach.type</a></li>
            
                <li data-name="IMMessage.scene"><a href="IMMessage.html#.scene">scene</a></li>
            
                <li data-name="IMMessage.type"><a href="IMMessage.html#.type">type</a></li>
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="LoginPort">
            <span class="title">
                <a href="LoginPort.html">LoginPort</a>
                
            </span>
            <ul class="members itemMembers">
            
            <span class="subtitle">Members</span>
            
                <li data-name="LoginPort.type"><a href="LoginPort.html#.type">type</a></li>
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="Netcall">
            <span class="title">
                <a href="Netcall.html">Netcall</a>
                
            </span>
            <ul class="members itemMembers">
            
            <span class="subtitle">Members</span>
            
                <li data-name="Netcall.CHAT_NET_STATUS_*"><a href="Netcall.html#.CHAT_NET_STATUS_*">CHAT_NET_STATUS_*</a></li>
            
                <li data-name="Netcall.CHAT_VIDEO_ENCODEMODE_*"><a href="Netcall.html#.CHAT_VIDEO_ENCODEMODE_*">CHAT_VIDEO_ENCODEMODE_*</a></li>
            
                <li data-name="Netcall.CHAT_VIDEO_FRAME_RATE_*"><a href="Netcall.html#.CHAT_VIDEO_FRAME_RATE_*">CHAT_VIDEO_FRAME_RATE_*</a></li>
            
                <li data-name="Netcall.CHAT_VIDEO_QUALITY_*"><a href="Netcall.html#.CHAT_VIDEO_QUALITY_*">CHAT_VIDEO_QUALITY_*</a></li>
            
                <li data-name="Netcall.CHAT_VIDEO_SCALE_*"><a href="Netcall.html#.CHAT_VIDEO_SCALE_*">CHAT_VIDEO_SCALE_*</a></li>
            
                <li data-name="Netcall.CLIENT_TYPE_*"><a href="Netcall.html#.CLIENT_TYPE_*">CLIENT_TYPE_*</a></li>
            
                <li data-name="Netcall.DEVICE_TYPE_*"><a href="Netcall.html#.DEVICE_TYPE_*">DEVICE_TYPE_*</a></li>
            
                <li data-name="Netcall.LAYOUT_*"><a href="Netcall.html#.LAYOUT_*">LAYOUT_*</a></li>
            
                <li data-name="Netcall.NETCALL_CONTROL_COMMAND_*"><a href="Netcall.html#.NETCALL_CONTROL_COMMAND_*">NETCALL_CONTROL_COMMAND_*</a></li>
            
                <li data-name="Netcall.NETCALL_TYPE_*"><a href="Netcall.html#.NETCALL_TYPE_*">NETCALL_TYPE_*</a></li>
            
                <li data-name="Netcall.NETDETECT_*"><a href="Netcall.html#.NETDETECT_*">NETDETECT_*</a></li>
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            <span class="subtitle">Methods</span>
            
                <li data-name="Netcall.getInstance"><a href="Netcall.html#.getInstance">getInstance</a></li>
            
                <li data-name="Netcall#call"><a href="Netcall.html#call">call</a></li>
            
                <li data-name="Netcall#control"><a href="Netcall.html#control">control</a></li>
            
                <li data-name="Netcall#createChannel"><a href="Netcall.html#createChannel">createChannel</a></li>
            
                <li data-name="Netcall#getAccount"><a href="Netcall.html#getAccount">getAccount</a></li>
            
                <li data-name="Netcall#getStartedDeviceOfType"><a href="Netcall.html#getStartedDeviceOfType">getStartedDeviceOfType</a></li>
            
                <li data-name="Netcall#getStoredDevicesOfType"><a href="Netcall.html#getStoredDevicesOfType">getStoredDevicesOfType</a></li>
            
                <li data-name="Netcall#hangup"><a href="Netcall.html#hangup">hangup</a></li>
            
                <li data-name="Netcall#hasDevicesOfType"><a href="Netcall.html#hasDevicesOfType">hasDevicesOfType</a></li>
            
                <li data-name="Netcall#hasStartedDeviceOfType"><a href="Netcall.html#hasStartedDeviceOfType">hasStartedDeviceOfType</a></li>
            
                <li data-name="Netcall#initSignal"><a href="Netcall.html#initSignal">initSignal</a></li>
            
                <li data-name="Netcall#isCurrentChannelId"><a href="Netcall.html#isCurrentChannelId">isCurrentChannelId</a></li>
            
                <li data-name="Netcall#joinChannel"><a href="Netcall.html#joinChannel">joinChannel</a></li>
            
                <li data-name="Netcall#leaveChannel"><a href="Netcall.html#leaveChannel">leaveChannel</a></li>
            
                <li data-name="Netcall#netDetect"><a href="Netcall.html#netDetect">netDetect</a></li>
            
                <li data-name="Netcall#notCurrentChannelId"><a href="Netcall.html#notCurrentChannelId">notCurrentChannelId</a></li>
            
                <li data-name="Netcall#response"><a href="Netcall.html#response">response</a></li>
            
                <li data-name="Netcall#resumeLocalStream"><a href="Netcall.html#resumeLocalStream">resumeLocalStream</a></li>
            
                <li data-name="Netcall#resumeRemoteStream"><a href="Netcall.html#resumeRemoteStream">resumeRemoteStream</a></li>
            
                <li data-name="Netcall#setAudioBlack"><a href="Netcall.html#setAudioBlack">setAudioBlack</a></li>
            
                <li data-name="Netcall#setAudioBlack"><a href="Netcall.html#setAudioBlack">setAudioBlack</a></li>
            
                <li data-name="Netcall#setAudioStart"><a href="Netcall.html#setAudioStart">setAudioStart</a></li>
            
                <li data-name="Netcall#setAudioStart"><a href="Netcall.html#setAudioStart">setAudioStart</a></li>
            
                <li data-name="Netcall#setCaptureVolume"><a href="Netcall.html#setCaptureVolume">setCaptureVolume</a></li>
            
                <li data-name="Netcall#setPlayVolume"><a href="Netcall.html#setPlayVolume">setPlayVolume</a></li>
            
                <li data-name="Netcall#setVideoBlack"><a href="Netcall.html#setVideoBlack">setVideoBlack</a></li>
            
                <li data-name="Netcall#setVideoScale"><a href="Netcall.html#setVideoScale">setVideoScale</a></li>
            
                <li data-name="Netcall#setVideoShow"><a href="Netcall.html#setVideoShow">setVideoShow</a></li>
            
                <li data-name="Netcall#setVideoViewRemoteSize"><a href="Netcall.html#setVideoViewRemoteSize">setVideoViewRemoteSize</a></li>
            
                <li data-name="Netcall#setVideoViewSize"><a href="Netcall.html#setVideoViewSize">setVideoViewSize</a></li>
            
                <li data-name="Netcall#startDevice"><a href="Netcall.html#startDevice">startDevice</a></li>
            
                <li data-name="Netcall#startLocalStream"><a href="Netcall.html#startLocalStream">startLocalStream</a></li>
            
                <li data-name="Netcall#startRecordAac"><a href="Netcall.html#startRecordAac">startRecordAac</a></li>
            
                <li data-name="Netcall#startRecordMp4"><a href="Netcall.html#startRecordMp4">startRecordMp4</a></li>
            
                <li data-name="Netcall#startRemoteStream"><a href="Netcall.html#startRemoteStream">startRemoteStream</a></li>
            
                <li data-name="Netcall#stopDevice"><a href="Netcall.html#stopDevice">stopDevice</a></li>
            
                <li data-name="Netcall#stopRecordAac"><a href="Netcall.html#stopRecordAac">stopRecordAac</a></li>
            
                <li data-name="Netcall#stopRecordMp4"><a href="Netcall.html#stopRecordMp4">stopRecordMp4</a></li>
            
                <li data-name="Netcall#stopRemoteStream"><a href="Netcall.html#stopRemoteStream">stopRemoteStream</a></li>
            
                <li data-name="Netcall#stopSignal"><a href="Netcall.html#stopSignal">stopSignal</a></li>
            
                <li data-name="Netcall#suspendLocalStream"><a href="Netcall.html#suspendLocalStream">suspendLocalStream</a></li>
            
                <li data-name="Netcall#suspendRemoteStream"><a href="Netcall.html#suspendRemoteStream">suspendRemoteStream</a></li>
            
                <li data-name="Netcall#switchAudioToVideo"><a href="Netcall.html#switchAudioToVideo">switchAudioToVideo</a></li>
            
                <li data-name="Netcall#switchVideoToAudio"><a href="Netcall.html#switchVideoToAudio">switchVideoToAudio</a></li>
            
                <li data-name="Netcall#updateRtmpUrl"><a href="Netcall.html#updateRtmpUrl">updateRtmpUrl</a></li>
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="NIM">
            <span class="title">
                <a href="NIM.html">NIM</a>
                
            </span>
            <ul class="members itemMembers">
            
            <span class="subtitle">Members</span>
            
                <li data-name="NIM.io"><a href="NIM.html#.io">io</a></li>
            
                <li data-name="NIM.naturalSort"><a href="NIM.html#.naturalSort">naturalSort</a></li>
            
                <li data-name="NIM.platform"><a href="NIM.html#.platform">platform</a></li>
            
                <li data-name="NIM.xhr"><a href="NIM.html#.xhr">xhr</a></li>
            
            </ul>
            <ul class="typedefs itemMembers">
            
            <span class="subtitle">Typedefs</span>
            
                <li data-name="NIM#publishEvent"><a href="NIM.html#publishEvent">publishEvent</a></li>
            
                <li data-name="NIM#querySubscribeEventsByAccounts"><a href="NIM.html#querySubscribeEventsByAccounts">querySubscribeEventsByAccounts</a></li>
            
                <li data-name="NIM#querySubscribeEventsByType"><a href="NIM.html#querySubscribeEventsByType">querySubscribeEventsByType</a></li>
            
                <li data-name="NIM#subscribeEvent"><a href="NIM.html#subscribeEvent">subscribeEvent</a></li>
            
                <li data-name="NIM#unSubscribeEventsByAccounts"><a href="NIM.html#unSubscribeEventsByAccounts">unSubscribeEventsByAccounts</a></li>
            
                <li data-name="NIM#unSubscribeEventsByType"><a href="NIM.html#unSubscribeEventsByType">unSubscribeEventsByType</a></li>
            
            </ul>
            <ul class="methods itemMembers">
            
            <span class="subtitle">Methods</span>
            
                <li data-name="NIM.getInstance"><a href="NIM.html#.getInstance">getInstance</a></li>
            
                <li data-name="NIM#acceptTeamInvite"><a href="NIM.html#acceptTeamInvite">acceptTeamInvite</a></li>
            
                <li data-name="NIM#addFriend"><a href="NIM.html#addFriend">addFriend</a></li>
            
                <li data-name="NIM#addTeamManagers"><a href="NIM.html#addTeamManagers">addTeamManagers</a></li>
            
                <li data-name="NIM#addTeamMembers"><a href="NIM.html#addTeamMembers">addTeamMembers</a></li>
            
                <li data-name="NIM#addToBlacklist"><a href="NIM.html#addToBlacklist">addToBlacklist</a></li>
            
                <li data-name="NIM#addToMutelist"><a href="NIM.html#addToMutelist">addToMutelist</a></li>
            
                <li data-name="NIM#applyFriend"><a href="NIM.html#applyFriend">applyFriend</a></li>
            
                <li data-name="NIM#applyTeam"><a href="NIM.html#applyTeam">applyTeam</a></li>
            
                <li data-name="NIM#audioToMp3"><a href="NIM.html#audioToMp3">audioToMp3</a></li>
            
                <li data-name="NIM#audioToText"><a href="NIM.html#audioToText">audioToText</a></li>
            
                <li data-name="NIM#blurImage"><a href="NIM.html#blurImage">blurImage</a></li>
            
                <li data-name="NIM#connect"><a href="NIM.html#connect">connect</a></li>
            
                <li data-name="NIM#createTeam"><a href="NIM.html#createTeam">createTeam</a></li>
            
                <li data-name="NIM#cropImage"><a href="NIM.html#cropImage">cropImage</a></li>
            
                <li data-name="NIM#cutFriends"><a href="NIM.html#cutFriends">cutFriends</a></li>
            
                <li data-name="NIM#cutFriendsByAccounts"><a href="NIM.html#cutFriendsByAccounts">cutFriendsByAccounts</a></li>
            
                <li data-name="NIM#cutLoginPorts"><a href="NIM.html#cutLoginPorts">cutLoginPorts</a></li>
            
                <li data-name="NIM#cutRelations"><a href="NIM.html#cutRelations">cutRelations</a></li>
            
                <li data-name="NIM#cutTeamMembers"><a href="NIM.html#cutTeamMembers">cutTeamMembers</a></li>
            
                <li data-name="NIM#cutTeamMembersByAccounts"><a href="NIM.html#cutTeamMembersByAccounts">cutTeamMembersByAccounts</a></li>
            
                <li data-name="NIM#cutTeams"><a href="NIM.html#cutTeams">cutTeams</a></li>
            
                <li data-name="NIM#deleteAllLocalMsgs"><a href="NIM.html#deleteAllLocalMsgs">deleteAllLocalMsgs</a></li>
            
                <li data-name="NIM#deleteAllLocalSysMsgs"><a href="NIM.html#deleteAllLocalSysMsgs">deleteAllLocalSysMsgs</a></li>
            
                <li data-name="NIM#deleteFriend"><a href="NIM.html#deleteFriend">deleteFriend</a></li>
            
                <li data-name="NIM#deleteLocalMsg"><a href="NIM.html#deleteLocalMsg">deleteLocalMsg</a></li>
            
                <li data-name="NIM#deleteLocalMsgsBySession"><a href="NIM.html#deleteLocalMsgsBySession">deleteLocalMsgsBySession</a></li>
            
                <li data-name="NIM#deleteLocalSession"><a href="NIM.html#deleteLocalSession">deleteLocalSession</a></li>
            
                <li data-name="NIM#deleteLocalSysMsg"><a href="NIM.html#deleteLocalSysMsg">deleteLocalSysMsg</a></li>
            
                <li data-name="NIM#deleteLocalTeam"><a href="NIM.html#deleteLocalTeam">deleteLocalTeam</a></li>
            
                <li data-name="NIM#deleteMsg"><a href="NIM.html#deleteMsg">deleteMsg</a></li>
            
                <li data-name="NIM#deleteSession"><a href="NIM.html#deleteSession">deleteSession</a></li>
            
                <li data-name="NIM#deleteSessions"><a href="NIM.html#deleteSessions">deleteSessions</a></li>
            
                <li data-name="NIM#disconnect"><a href="NIM.html#disconnect">disconnect</a></li>
            
                <li data-name="NIM#dismissTeam"><a href="NIM.html#dismissTeam">dismissTeam</a></li>
            
                <li data-name="NIM#findFriend"><a href="NIM.html#findFriend">findFriend</a></li>
            
                <li data-name="NIM#findMsg"><a href="NIM.html#findMsg">findMsg</a></li>
            
                <li data-name="NIM#findRelation"><a href="NIM.html#findRelation">findRelation</a></li>
            
                <li data-name="NIM#findSession"><a href="NIM.html#findSession">findSession</a></li>
            
                <li data-name="NIM#findSysMsg"><a href="NIM.html#findSysMsg">findSysMsg</a></li>
            
                <li data-name="NIM#findTeam"><a href="NIM.html#findTeam">findTeam</a></li>
            
                <li data-name="NIM#findTeamMember"><a href="NIM.html#findTeamMember">findTeamMember</a></li>
            
                <li data-name="NIM#findUser"><a href="NIM.html#findUser">findUser</a></li>
            
                <li data-name="NIM#forwardMsg"><a href="NIM.html#forwardMsg">forwardMsg</a></li>
            
                <li data-name="NIM#getChatroomAddress"><a href="NIM.html#getChatroomAddress">getChatroomAddress</a></li>
            
                <li data-name="NIM#getFriends"><a href="NIM.html#getFriends">getFriends</a></li>
            
                <li data-name="NIM#getHistoryMsgs"><a href="NIM.html#getHistoryMsgs">getHistoryMsgs</a></li>
            
                <li data-name="NIM#getLocalMsgByIdClient"><a href="NIM.html#getLocalMsgByIdClient">getLocalMsgByIdClient</a></li>
            
                <li data-name="NIM#getLocalMsgs"><a href="NIM.html#getLocalMsgs">getLocalMsgs</a></li>
            
                <li data-name="NIM#getLocalMsgsByIdClients"><a href="NIM.html#getLocalMsgsByIdClients">getLocalMsgsByIdClients</a></li>
            
                <li data-name="NIM#getLocalSessions"><a href="NIM.html#getLocalSessions">getLocalSessions</a></li>
            
                <li data-name="NIM#getLocalSysMsgs"><a href="NIM.html#getLocalSysMsgs">getLocalSysMsgs</a></li>
            
                <li data-name="NIM#getLocalTeams"><a href="NIM.html#getLocalTeams">getLocalTeams</a></li>
            
                <li data-name="NIM#getMutedTeamMembers"><a href="NIM.html#getMutedTeamMembers">getMutedTeamMembers</a></li>
            
                <li data-name="NIM#getPushNotificationMultiportConfig"><a href="NIM.html#getPushNotificationMultiportConfig">getPushNotificationMultiportConfig</a></li>
            
                <li data-name="NIM#getRelations"><a href="NIM.html#getRelations">getRelations</a></li>
            
                <li data-name="NIM#getTeam"><a href="NIM.html#getTeam">getTeam</a></li>
            
                <li data-name="NIM#getTeamMembers"><a href="NIM.html#getTeamMembers">getTeamMembers</a></li>
            
                <li data-name="NIM#getTeams"><a href="NIM.html#getTeams">getTeams</a></li>
            
                <li data-name="NIM#getUser"><a href="NIM.html#getUser">getUser</a></li>
            
                <li data-name="NIM#getUsers"><a href="NIM.html#getUsers">getUsers</a></li>
            
                <li data-name="NIM#insertLocalSession"><a href="NIM.html#insertLocalSession">insertLocalSession</a></li>
            
                <li data-name="NIM#interlaceImage"><a href="NIM.html#interlaceImage">interlaceImage</a></li>
            
                <li data-name="NIM#isMsgRemoteRead"><a href="NIM.html#isMsgRemoteRead">isMsgRemoteRead</a></li>
            
                <li data-name="NIM#kick"><a href="NIM.html#kick">kick</a></li>
            
                <li data-name="NIM#leaveTeam"><a href="NIM.html#leaveTeam">leaveTeam</a></li>
            
                <li data-name="NIM#markInBlacklist"><a href="NIM.html#markInBlacklist">markInBlacklist</a></li>
            
                <li data-name="NIM#markInMutelist"><a href="NIM.html#markInMutelist">markInMutelist</a></li>
            
                <li data-name="NIM#markMsgRead"><a href="NIM.html#markMsgRead">markMsgRead</a></li>
            
                <li data-name="NIM#markSysMsgRead"><a href="NIM.html#markSysMsgRead">markSysMsgRead</a></li>
            
                <li data-name="NIM#mergeFriends"><a href="NIM.html#mergeFriends">mergeFriends</a></li>
            
                <li data-name="NIM#mergeLoginPorts"><a href="NIM.html#mergeLoginPorts">mergeLoginPorts</a></li>
            
                <li data-name="NIM#mergeMsgs"><a href="NIM.html#mergeMsgs">mergeMsgs</a></li>
            
                <li data-name="NIM#mergeRelations"><a href="NIM.html#mergeRelations">mergeRelations</a></li>
            
                <li data-name="NIM#mergeSessions"><a href="NIM.html#mergeSessions">mergeSessions</a></li>
            
                <li data-name="NIM#mergeSysMsgs"><a href="NIM.html#mergeSysMsgs">mergeSysMsgs</a></li>
            
                <li data-name="NIM#mergeTeamMembers"><a href="NIM.html#mergeTeamMembers">mergeTeamMembers</a></li>
            
                <li data-name="NIM#mergeTeams"><a href="NIM.html#mergeTeams">mergeTeams</a></li>
            
                <li data-name="NIM#mergeUsers"><a href="NIM.html#mergeUsers">mergeUsers</a></li>
            
                <li data-name="NIM#notifyForNewTeamMsg"><a href="NIM.html#notifyForNewTeamMsg">notifyForNewTeamMsg</a></li>
            
                <li data-name="NIM#packFileDownloadName"><a href="NIM.html#packFileDownloadName">packFileDownloadName</a></li>
            
                <li data-name="NIM#passFriendApply"><a href="NIM.html#passFriendApply">passFriendApply</a></li>
            
                <li data-name="NIM#passTeamApply"><a href="NIM.html#passTeamApply">passTeamApply</a></li>
            
                <li data-name="NIM#previewFile"><a href="NIM.html#previewFile">previewFile</a></li>
            
                <li data-name="NIM#processImage"><a href="NIM.html#processImage">processImage</a></li>
            
                <li data-name="NIM#qualityImage"><a href="NIM.html#qualityImage">qualityImage</a></li>
            
                <li data-name="NIM#rejectFriendApply"><a href="NIM.html#rejectFriendApply">rejectFriendApply</a></li>
            
                <li data-name="NIM#rejectTeamApply"><a href="NIM.html#rejectTeamApply">rejectTeamApply</a></li>
            
                <li data-name="NIM#rejectTeamInvite"><a href="NIM.html#rejectTeamInvite">rejectTeamInvite</a></li>
            
                <li data-name="NIM#removeFromBlacklist"><a href="NIM.html#removeFromBlacklist">removeFromBlacklist</a></li>
            
                <li data-name="NIM#removeFromMutelist"><a href="NIM.html#removeFromMutelist">removeFromMutelist</a></li>
            
                <li data-name="NIM#removeTeamManagers"><a href="NIM.html#removeTeamManagers">removeTeamManagers</a></li>
            
                <li data-name="NIM#removeTeamMembers"><a href="NIM.html#removeTeamMembers">removeTeamMembers</a></li>
            
                <li data-name="NIM#resendMsg"><a href="NIM.html#resendMsg">resendMsg</a></li>
            
                <li data-name="NIM#resetCurrSession"><a href="NIM.html#resetCurrSession">resetCurrSession</a></li>
            
                <li data-name="NIM#resetSessionUnread"><a href="NIM.html#resetSessionUnread">resetSessionUnread</a></li>
            
                <li data-name="NIM#rotateImage"><a href="NIM.html#rotateImage">rotateImage</a></li>
            
                <li data-name="NIM#sendCustomMsg"><a href="NIM.html#sendCustomMsg">sendCustomMsg</a></li>
            
                <li data-name="NIM#sendCustomSysMsg"><a href="NIM.html#sendCustomSysMsg">sendCustomSysMsg</a></li>
            
                <li data-name="NIM#sendFile"><a href="NIM.html#sendFile">sendFile</a></li>
            
                <li data-name="NIM#sendGeo"><a href="NIM.html#sendGeo">sendGeo</a></li>
            
                <li data-name="NIM#sendMsgReceipt"><a href="NIM.html#sendMsgReceipt">sendMsgReceipt</a></li>
            
                <li data-name="NIM#sendRobotMsg"><a href="NIM.html#sendRobotMsg">sendRobotMsg</a></li>
            
                <li data-name="NIM#sendText"><a href="NIM.html#sendText">sendText</a></li>
            
                <li data-name="NIM#sendTipMsg"><a href="NIM.html#sendTipMsg">sendTipMsg</a></li>
            
                <li data-name="NIM#setCurrSession"><a href="NIM.html#setCurrSession">setCurrSession</a></li>
            
                <li data-name="NIM#setOptions"><a href="NIM.html#setOptions">setOptions</a></li>
            
                <li data-name="NIM#stripImageMeta"><a href="NIM.html#stripImageMeta">stripImageMeta</a></li>
            
                <li data-name="NIM#thumbnailImage"><a href="NIM.html#thumbnailImage">thumbnailImage</a></li>
            
                <li data-name="NIM#transferTeam"><a href="NIM.html#transferTeam">transferTeam</a></li>
            
                <li data-name="NIM#updateFriend"><a href="NIM.html#updateFriend">updateFriend</a></li>
            
                <li data-name="NIM#updateInfoInTeam"><a href="NIM.html#updateInfoInTeam">updateInfoInTeam</a></li>
            
                <li data-name="NIM#updateLocalMsg"><a href="NIM.html#updateLocalMsg">updateLocalMsg</a></li>
            
                <li data-name="NIM#updateLocalSession"><a href="NIM.html#updateLocalSession">updateLocalSession</a></li>
            
                <li data-name="NIM#updateLocalSysMsg"><a href="NIM.html#updateLocalSysMsg">updateLocalSysMsg</a></li>
            
                <li data-name="NIM#updateMuteStateInTeam"><a href="NIM.html#updateMuteStateInTeam">updateMuteStateInTeam</a></li>
            
                <li data-name="NIM#updateMyInfo"><a href="NIM.html#updateMyInfo">updateMyInfo</a></li>
            
                <li data-name="NIM#updateNickInTeam"><a href="NIM.html#updateNickInTeam">updateNickInTeam</a></li>
            
                <li data-name="NIM#updateTeam"><a href="NIM.html#updateTeam">updateTeam</a></li>
            
                <li data-name="NIM#viewImageStripMeta"><a href="NIM.html#viewImageStripMeta">viewImageStripMeta</a></li>
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="NIMError">
            <span class="title">
                <a href="NIMError.html">NIMError</a>
                
            </span>
            <ul class="members itemMembers">
            
            <span class="subtitle">Members</span>
            
                <li data-name="NIMError.codeMap"><a href="NIMError.html#.codeMap">codeMap</a></li>
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="Relation">
            <span class="title">
                <a href="Relation.html">Relation</a>
                
            </span>
            <ul class="members itemMembers">
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="SdkData">
            <span class="title">
                <a href="SdkData.html">SdkData</a>
                
            </span>
            <ul class="members itemMembers">
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="Session">
            <span class="title">
                <a href="Session.html">Session</a>
                
            </span>
            <ul class="members itemMembers">
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="Stream">
            <span class="title">
                <a href="Stream.html">Stream</a>
                
            </span>
            <ul class="members itemMembers">
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="SystemMessage">
            <span class="title">
                <a href="SystemMessage.html">SystemMessage</a>
                
            </span>
            <ul class="members itemMembers">
            
            <span class="subtitle">Members</span>
            
                <li data-name="SystemMessage.category"><a href="SystemMessage.html#.category">category</a></li>
            
                <li data-name="SystemMessage.state"><a href="SystemMessage.html#.state">state</a></li>
            
                <li data-name="SystemMessage.type"><a href="SystemMessage.html#.type">type</a></li>
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="Team">
            <span class="title">
                <a href="Team.html">Team</a>
                
            </span>
            <ul class="members itemMembers">
            
            <span class="subtitle">Members</span>
            
                <li data-name="Team.beInviteMode"><a href="Team.html#.beInviteMode">beInviteMode</a></li>
            
                <li data-name="Team.inviteMode"><a href="Team.html#.inviteMode">inviteMode</a></li>
            
                <li data-name="Team.joinMode"><a href="Team.html#.joinMode">joinMode</a></li>
            
                <li data-name="Team.type"><a href="Team.html#.type">type</a></li>
            
                <li data-name="Team.updateCustomMode"><a href="Team.html#.updateCustomMode">updateCustomMode</a></li>
            
                <li data-name="Team.updateTeamMode"><a href="Team.html#.updateTeamMode">updateTeamMode</a></li>
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            <span class="subtitle">Methods</span>
            
                <li data-name="Team.fillProperties"><a href="Team.html#.fillProperties">fillProperties</a></li>
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="TeamMember">
            <span class="title">
                <a href="TeamMember.html">TeamMember</a>
                
            </span>
            <ul class="members itemMembers">
            
            <span class="subtitle">Members</span>
            
                <li data-name="TeamMember.type"><a href="TeamMember.html#.type">type</a></li>
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            <span class="subtitle">Methods</span>
            
                <li data-name="TeamMember.fillProperties"><a href="TeamMember.html#.fillProperties">fillProperties</a></li>
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="User">
            <span class="title">
                <a href="User.html">User</a>
                
            </span>
            <ul class="members itemMembers">
            
            <span class="subtitle">Members</span>
            
                <li data-name="User.gender"><a href="User.html#.gender">gender</a></li>
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="Video">
            <span class="title">
                <a href="Video.html">Video</a>
                
            </span>
            <ul class="members itemMembers">
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
        <li class="item" data-name="WebRTC">
            <span class="title">
                <a href="WebRTC.html">WebRTC</a>
                
            </span>
            <ul class="members itemMembers">
            
            <span class="subtitle">Members</span>
            
                <li data-name="WebRTC.CHAT_VIDEO_FRAME_RATE_*"><a href="WebRTC.html#.CHAT_VIDEO_FRAME_RATE_*">CHAT_VIDEO_FRAME_RATE_*</a></li>
            
                <li data-name="WebRTC.CHAT_VIDEO_QUALITY_*"><a href="WebRTC.html#.CHAT_VIDEO_QUALITY_*">CHAT_VIDEO_QUALITY_*</a></li>
            
                <li data-name="WebRTC.DEVICE_TYPE_*"><a href="WebRTC.html#.DEVICE_TYPE_*">DEVICE_TYPE_*</a></li>
            
                <li data-name="WebRTC.LAYOUT_*"><a href="WebRTC.html#.LAYOUT_*">LAYOUT_*</a></li>
            
                <li data-name="WebRTC.NETCALL_CONTROL_COMMAND_*"><a href="WebRTC.html#.NETCALL_CONTROL_COMMAND_*">NETCALL_CONTROL_COMMAND_*</a></li>
            
                <li data-name="WebRTC.NETCALL_TYPE_*"><a href="WebRTC.html#.NETCALL_TYPE_*">NETCALL_TYPE_*</a></li>
            
            </ul>
            <ul class="typedefs itemMembers">
            
            </ul>
            <ul class="methods itemMembers">
            
            <span class="subtitle">Methods</span>
            
                <li data-name="WebRTC.getInstance"><a href="WebRTC.html#.getInstance">getInstance</a></li>
            
                <li data-name="WebRTC#call"><a href="WebRTC.html#call">call</a></li>
            
                <li data-name="WebRTC#changeRoleToAudience"><a href="WebRTC.html#changeRoleToAudience">changeRoleToAudience</a></li>
            
                <li data-name="WebRTC#changeRoleToPlayer"><a href="WebRTC.html#changeRoleToPlayer">changeRoleToPlayer</a></li>
            
                <li data-name="WebRTC#control"><a href="WebRTC.html#control">control</a></li>
            
                <li data-name="WebRTC#createChannel"><a href="WebRTC.html#createChannel">createChannel</a></li>
            
                <li data-name="WebRTC#getAccount"><a href="WebRTC.html#getAccount">getAccount</a></li>
            
                <li data-name="WebRTC#hangup"><a href="WebRTC.html#hangup">hangup</a></li>
            
                <li data-name="WebRTC#initSignal"><a href="WebRTC.html#initSignal">initSignal</a></li>
            
                <li data-name="WebRTC#isCurrentChannelId"><a href="WebRTC.html#isCurrentChannelId">isCurrentChannelId</a></li>
            
                <li data-name="WebRTC#isCurrentChannelId"><a href="WebRTC.html#isCurrentChannelId">isCurrentChannelId</a></li>
            
                <li data-name="WebRTC#joinChannel"><a href="WebRTC.html#joinChannel">joinChannel</a></li>
            
                <li data-name="WebRTC#leaveChannel"><a href="WebRTC.html#leaveChannel">leaveChannel</a></li>
            
                <li data-name="WebRTC#response"><a href="WebRTC.html#response">response</a></li>
            
                <li data-name="WebRTC#resumeLocalStream"><a href="WebRTC.html#resumeLocalStream">resumeLocalStream</a></li>
            
                <li data-name="WebRTC#setCaptureVolume"><a href="WebRTC.html#setCaptureVolume">setCaptureVolume</a></li>
            
                <li data-name="WebRTC#setPlayVolume"><a href="WebRTC.html#setPlayVolume">setPlayVolume</a></li>
            
                <li data-name="WebRTC#setVideoViewRemoteSize"><a href="WebRTC.html#setVideoViewRemoteSize">setVideoViewRemoteSize</a></li>
            
                <li data-name="WebRTC#setVideoViewSize"><a href="WebRTC.html#setVideoViewSize">setVideoViewSize</a></li>
            
                <li data-name="WebRTC#startDevice"><a href="WebRTC.html#startDevice">startDevice</a></li>
            
                <li data-name="WebRTC#startLocalStream"><a href="WebRTC.html#startLocalStream">startLocalStream</a></li>
            
                <li data-name="WebRTC#startRecordAac"><a href="WebRTC.html#startRecordAac">startRecordAac</a></li>
            
                <li data-name="WebRTC#startRecordMp4"><a href="WebRTC.html#startRecordMp4">startRecordMp4</a></li>
            
                <li data-name="WebRTC#startRtc"><a href="WebRTC.html#startRtc">startRtc</a></li>
            
                <li data-name="WebRTC#stopDevice"><a href="WebRTC.html#stopDevice">stopDevice</a></li>
            
                <li data-name="WebRTC#stopRecordAac"><a href="WebRTC.html#stopRecordAac">stopRecordAac</a></li>
            
                <li data-name="WebRTC#stopRecordMp4"><a href="WebRTC.html#stopRecordMp4">stopRecordMp4</a></li>
            
                <li data-name="WebRTC#suspendLocalStream"><a href="WebRTC.html#suspendLocalStream">suspendLocalStream</a></li>
            
                <li data-name="WebRTC#switchAudioToVideo"><a href="WebRTC.html#switchAudioToVideo">switchAudioToVideo</a></li>
            
                <li data-name="WebRTC#switchVideoToAudio"><a href="WebRTC.html#switchVideoToAudio">switchVideoToAudio</a></li>
            
            </ul>
            <ul class="events itemMembers">
            
            </ul>
        </li>
    
    </ul>
</div>
    <div class="main">
        <h1 class="page-title" data-filename="Chatroom.html">Class: Chatroom</h1>
        



<section>
    
<header>
    <h2>
    Chatroom
    </h2>
    
</header>  

<article>
    <div class="container-overview">
    
    
    
        
<dt>
    <div class="nameContainer">
        <h4 class="name" id="Chatroom">
            
            new Chatroom<span class="signature">()</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/index.js, line 25
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>请使用 <a href="Chatroom.html#.getInstance"><code>Chatroom.getInstance</code></a> 来初始化聊天室.<br>此接口为单例模式, 对于同一个账号的同一个聊天室, 永远返回同一份实例, 即只有第一次调用会初始化一个实例, 后续调用此接口会直接返回初始化过的实例.</p>
    </div>
    

    
    
    
    
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    
    

    
</dd>

    
    </div>
    
    
    
    
    
    
    
    
    
    
    
    
        <h3 class="subsection-title">Members</h3>
        
        <dl>
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id=".deepAccess"><span class="type-signature static">static</span>Chatroom.deepAccess<span class="type-signature type function">function</span> </h4>
    </div>
    
    
</dt>
<dd>
    
    <div class="description">
        <p>SDK 使用 <a target="_blank" href="https://github.com/juliangruber/deep-access">deep access</a> 来获取对象的属性值, 通过 <code>Chatroom.deepAccess</code> 来获取此库的引用</p>
    </div>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id=".io"><span class="type-signature static">static</span>Chatroom.io<span class="type-signature type object">Object</span> </h4>
    </div>
    
    
</dt>
<dd>
    
    <div class="description">
        <p>SDK 使用 <a target="_blank" href="https://github.com/socketio/socket.io-client/tree/0.9">socket.io-client 0.9</a> 来建立 Socket 连接, 通过 <code>Chatroom.io</code> 来获取此库的引用</p>
    </div>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id=".naturalSort"><span class="type-signature static">static</span>Chatroom.naturalSort<span class="type-signature type function">function</span> </h4>
    </div>
    
    
</dt>
<dd>
    
    <div class="description">
        <p>SDK 使用 <a target="_blank" href="https://github.com/Bill4Time/javascript-natural-sort">natural sort</a> 来对数组进行排序, 通过 <code>Chatroom.naturalSort</code> 来获取此库的引用</p>
    </div>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id=".platform"><span class="type-signature static">static</span>Chatroom.platform<span class="type-signature type object">Object</span> </h4>
    </div>
    
    
</dt>
<dd>
    
    <div class="description">
        <p>SDK 使用 <a target="_blank" href="https://github.com/bestiejs/platform.js/">platform.js</a> 来检测浏览器平台, 通过 <code>Chatroom.platform</code> 来获取此库的引用</p>
    </div>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id=".xhr"><span class="type-signature static">static</span>Chatroom.xhr<span class="type-signature type function">function</span> </h4>
    </div>
    
    
</dt>
<dd>
    
    <div class="description">
        <p>SDK 使用 <a target="_blank" href="https://github.com/Raynos/xhr">xhr</a> 来发送 Ajax 请求, 通过 <code>Chatroom.xhr</code> 来获取此库的引用</p>
    </div>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    
</dd>

        </dl>
    
    
    
        <h3 class="subsection-title">Methods</h3>
        
        <dl>
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id=".getInstance">
            
            <span class="type-signature static">static</span>Chatroom.getInstance<span class="signature">(options)</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/index.js, line 46
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <ul>
<li>此接口为单例模式, 对于同一个账号, 永远返回同一份实例, 即只有第一次调用会初始化一个实例</li>
<li>后续调用此接口会直接返回初始化过的实例, 同时也会调用接口<a href="Chatroom.html#setOptions"><code>setOptions</code></a>更新传入的配置</li>
<li>后续调用此接口时, 如果连接已断开, 会自动建立连接</li>
<li>当发生掉线时，SDK会自动进行重连</li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		<th>Default</th>
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>secure</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>
|

<span class="param-type">Object</span>


            
            </td>
            
            
                <td class="default">
                
                    true
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>secure 模式下会通过 https 协议跟服务器建立连接, 非 secure 模式下会通过 http 协议跟服务器建立连接, 默认 true</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>appKey</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>在云信管理后台查看应用的 appKey</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>account</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>帐号, 应用内唯一</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>token</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>帐号的 token, 用于建立连接</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>chatroomId</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>聊天室 id</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>chatroomAddresses</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Array.&lt;String></span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>聊天室地址列表</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>onconnect</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">function</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>连接建立后的回调, 会传入<a href="ChatroomInfo.html"><code>聊天室信息</code></a></p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>onwillreconnect</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">function</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>即将重连的回调</p>
<ul>
<li>此时说明 SDK 已经断开连接, 请开发者在界面上提示用户连接已断开, 而且正在重新建立连接</li>
<li>此回调会收到一个对象, 包含额外的信息, 有以下字段<ul>
<li><code>duration</code>: 距离下次重连的时间</li>
<li><code>retryCount</code>: 重连尝试的次数</li>
</ul>
</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>ondisconnect</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">function</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>断开连接后的回调</p>
<ul>
<li>此时说明 SDK 处于断开状态, 开发者此时应该根据错误码提示相应的错误信息, 并且跳转到登录页面</li>
<li>此回调会收到一个对象, 包含错误的信息, 有以下字段<ul>
<li><code>code</code>: 出错时的错误码, 可能为空<ul>
<li><code>302</code>: 账号或者密码错误</li>
<li><code>'kicked'</code>: 被踢</li>
</ul>
</li>
</ul>
</li>
<li>当<code>code</code>为<code>'kicked'</code>的时候, 此对象会有以下字段<ul>
<li><code>reason</code>: 被踢的原因<ul>
<li><code>chatroomClosed</code>: 聊天室关闭了</li>
<li><code>managerKick</code>: 被管理员踢出</li>
<li><code>samePlatformKick</code>: 不允许同一个帐号重复登录同一个聊天室</li>
</ul>
</li>
<li><code>message</code>: 文字描述的被踢的原因</li>
</ul>
</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>onerror</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">function</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>发生错误的回调, 会传入<a href="NIMError.html"><code>错误</code></a>对象</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>onmsgs</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">function</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>收到消息的回调, 会传入<a href="ChatroomMessage.html"><code>消息</code></a>数组</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>var chatroom = new Chatroom({<br>    appKey: 'appKey',<br>    account: 'account',<br>    token: 'token',<br>    chatroomId: 'chatroomId',<br>    chatroomAddresses: [<br>        'address1',<br>        'address2'<br>    ],<br>    onconnect: onChatroomConnect,<br>    onerror: onChatroomError,<br>    onwillreconnect: onChatroomWillReconnect,<br>    ondisconnect: onChatroomDisconnect,<br>    // 消息<br>    onmsgs: onChatroomMsgs<br>});<br>function onChatroomConnect(chatroomInfo) {<br>    console.log('进入聊天室', chatroomInfo);<br>}<br>function onChatroomWillReconnect(obj) {<br>    // 此时说明 <code>SDK</code> 已经断开连接, 请开发者在界面上提示用户连接已断开, 而且正在重新建立连接<br>    console.log('即将重连', obj);<br>}<br>function onChatroomDisconnect(error) {<br>    // 此时说明 <code>SDK</code> 处于断开状态, 开发者此时应该根据错误码提示相应的错误信息, 并且跳转到登录页面<br>    console.log('连接断开', error);<br>    if (error) {<br>        switch (error.code) {<br>        // 账号或者密码错误, 请跳转到登录页面并提示错误<br>        case 302:<br>            break;<br>        // 被踢, 请提示错误后跳转到登录页面<br>        case 'kicked':<br>            break;<br>        default:<br>            break;<br>        }<br>    }<br>}<br>function onChatroomError(error, obj) {<br>    console.log('发生错误', error, obj);<br>}<br>function onChatroomMsgs(msgs) {<br>    console.log('收到聊天室消息', msgs);<br>}</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="audioToMp3">
            
            audioToMp3<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{String}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/nos.js, line 21
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>将音频 url 转为 mp3</p>
<ul>
<li>此方法会返回一个新的 url</li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>url</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>url</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        String
                        
                    
            </td>
            <td class="description last">转为 mp3 后的 url</td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>var url = 'http://b12026.nos.netease.com/MTAxMTAxMA==/bmltYV8xMTQwMzFfMTQ1MTg4ODk5MjMxMV9mNmI1Y2QyZC03N2UzLTQxNmUtYWY5NC1iODlhZGY4ZTYzYWQ=';<br>var mp3Url = chatroom.audioToMp3({<br>    url: url<br>});<br>console.log(mp3Url);</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="connect">
            
            connect<span class="signature">()</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/connect.js, line 2
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>进入聊天室</p>
    </div>
    

    
    
    
    
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                        
                    
            </td>
            <td class="description last"></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.connect();</p></code></pre>
    

    

    
    <dt class="tag-see">See:</dt>
    <dd class="tag-see">
        <ul>
            <li><a href="Chatroom.html#disconnect"><code>disconnect</code></a></li>
        </ul>
    </dd>
    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="disconnect">
            
            disconnect<span class="signature">()</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/connect.js, line 16
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>退出聊天室</p>
    </div>
    

    
    
    
    
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                        
                    
            </td>
            <td class="description last"></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.disconnect();</p></code></pre>
    

    

    
    <dt class="tag-see">See:</dt>
    <dd class="tag-see">
        <ul>
            <li><a href="Chatroom.html#connect"><code>connect</code></a></li>
        </ul>
    </dd>
    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="getChatroom">
            
            getChatroom<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/index.js, line 166
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>获取聊天室信息</p>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>done</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">function</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>结果回调函数, 成功时会额外附上<a href="ChatroomInfo.html"><code>聊天室信息</code></a></p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                        
                    
            </td>
            <td class="description last"></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.getChatroom({<br>    done: getChatroomDone<br>});<br>function getChatroomDone(error, obj) {<br>    console.log('获取聊天室信息' + (!error?'成功':'失败'), error, obj);<br>}</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="getChatroomMembers">
            
            getChatroomMembers<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/member.js, line 54
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>获取聊天室成员列表</p>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		<th>Default</th>
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>guest</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p><code>true</code>表示获取游客, <code>false</code>表示获取非游客成员</p>
<ul>
<li>游客列表按照游客进入聊天室的时间倒序排列</li>
<li>非游客（即固定成员）列表按照成为固定成员的时间倒序排列</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>onlyOnline</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
                <td class="default">
                
                    false
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>当设置<code>guest=false</code>来获取非游客成员时, 默认会获取所有的固定成员, 包括不在线的, 可以设置<code>onlyOnline=true</code>来只获取在线的固定成员</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>time</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Number</span>


            
            </td>
            
            
                <td class="default">
                
                    0
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>分页用, 查找该时间戳之前的成员</p>
<ul>
<li>默认 0 代表当前服务器时间</li>
<li>获取游客时, 此字段填上次获取的最后一个游客的<code>enterTime</code></li>
<li>获取非游客时, 此字段填上次获取的最后一个非游客的<code>updateTime</code></li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>limit</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Number</span>


            
            </td>
            
            
                <td class="default">
                
                    100
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>分页用, 默认 100</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>done</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">done</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>结果回调函数, 成功时会额外附上<a href="ChatroomMember.html"><code>聊天室成员信息</code></a>列表</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                        
                    
            </td>
            <td class="description last"></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.getChatroomMembers({<br>    guest: false,<br>    limit: 100,<br>    done: getChatroomMembersDone<br>});<br>function getChatroomMembersDone(error, obj) {<br>    console.log('获取聊天室成员' + (!error?'成功':'失败'), error, obj.members);<br>}</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="getChatroomMembersInfo">
            
            getChatroomMembersInfo<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/member.js, line 106
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>获取聊天室成员信息</p>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>accounts</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Array.&lt;String></span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>待查询的账号列表, 每次最多20个</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>done</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">function</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>结果回调函数, 成功时会额外附上<a href="ChatroomMember.html"><code>聊天室成员信息</code></a>列表</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                        
                    
            </td>
            <td class="description last"></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.getChatroomMembersInfo({<br>    accounts: ['account1', 'account2'],<br>    done: getChatroomMembersInfoDone<br>});<br>function getChatroomMembersInfoDone(erorr, obj) {<br>    console.log('获取聊天室成员信息' + (!error?'成功':'失败'), error, obj);<br>}</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="getHistoryMsgs">
            
            getHistoryMsgs<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/msg.js, line 294
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>获取聊天室历史消息</p>
<ul>
<li>获取从 timetag 对应的时间点往前的若干条数据</li>
<li>不填 timetag 的话默认为服务器当前时间</li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		<th>Default</th>
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>timetag</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Number</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>时间戳</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>limit</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Number</span>


            
            </td>
            
            
                <td class="default">
                
                    100
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>limit, 默认 100</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>reverse</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
                <td class="default">
                
                    false
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>默认<code>false</code>表示从<code>timetag</code>开始往前查找历史消息;<br>                                             <code>true</code>表示从<code>timetag</code>开始往后查找历史消息                                             <code>true</code>表示从<code>beginTime</code>开始往后查找历史消息</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                        
                    
            </td>
            <td class="description last"></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.getHistoryMsgs({<br>    timetag: 1451393192478,<br>    limit: 100,<br>    done: getHistoryMsgsDone<br>});<br>function getHistoryMsgsDone(error, obj) {<br>    console.log('获取聊天室历史' + (!error?'成功':'失败'), error, obj.msgs);<br>}</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="kickChatroomMember">
            
            kickChatroomMember<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/member.js, line 279
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>踢聊天室成员</p>
<ul>
<li>当有人被<a href="Chatroom.html#kickChatroomMember"><code>踢出聊天室</code></a>时, 所有聊天室成员会收到类型为<a href="ChatroomMessage.html#.type"><code>'<code>kickMember</code>'</code></a>的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>。</li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>account</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>待踢的账号</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>custom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>扩展字段, 如果填了, 那么其它聊天室成员收到的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>的<code>attach.custom</code>的值为此字段, 被踢的人收到的<code>ondisconnect</code>回调接收的参数的<code>custom</code>的值为此字段</p>
<ul>
<li>推荐使用<code>JSON</code>格式构建, 非<code>JSON</code>格式的话, Web端会正常接收, 但是会被其它端丢弃</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>done</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">function</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>结果回调函数</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                        
                    
            </td>
            <td class="description last"></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.kickChatroomMember({<br>    account: 'account',<br>    done: kickChatroomMemberDone<br>});<br>function kickChatroomMember(error, obj) {<br>    console.log('踢人' + (!error?'成功':'失败'), error, obj);<br>}</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="markChatroomBlacklist">
            
            markChatroomBlacklist<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/member.js, line 199
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>设置聊天室黑名单</p>
<ul>
<li>被加入黑名单的人将不能进入此聊天室</li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>account</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>待设置的账号</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>isAdd</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p><code>true</code>表示添加, <code>false</code>表示移除</p>
<ul>
<li>当有人被<a href="Chatroom.html#markChatroomBlacklist"><code>加入黑名单</code></a>时, 所有聊天室成员会收到类型为<a href="ChatroomMessage.html#.attach.type"><code><code>'blackMember'</code></code></a>的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>。</li>
<li>当有人被<a href="Chatroom.html#markChatroomBlacklist"><code>移除黑名单</code></a>时, 所有聊天室成员会收到类型为<a href="ChatroomMessage.html#.attach.type"><code><code>'blackMember'</code></code></a>的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>。</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>custom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>扩展字段, 如果填了, 那么其它聊天室成员收到的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>的<code>attach.custom</code>的值为此字段</p>
<ul>
<li>推荐使用<code>JSON</code>格式构建, 非<code>JSON</code>格式的话, Web端会正常接收, 但是会被其它端丢弃</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>done</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">function</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>结果回调函数, 成功时会额外附上<a href="ChatroomMember.html"><code>聊天室成员信息</code></a></p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                        
                    
            </td>
            <td class="description last"></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.markChatroomBlacklist({<br>    account: 'account',<br>    isAdd: true,<br>    done: markChatroomBlacklistDone<br>});<br>function markChatroomBlacklistDone(error, obj) {<br>    console.log('添加聊天室黑名单' + (!error?'成功':'失败'), error, obj.member);<br>}</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="markChatroomCommonMember">
            
            markChatroomCommonMember<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/member.js, line 167
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>设置聊天室普通成员</p>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		<th>Default</th>
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>account</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>待设置的账号</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>isAdd</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>是否加为普通成员</p>
<ul>
<li>当有人被<a href="Chatroom.html#markChatroomCommonMember"><code>加为普通成员</code></a>时, 所有聊天室成员会收到类型为<a href="ChatroomMessage.html#.attach.type"><code><code>'addCommon'</code></code></a>的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>。</li>
<li>当有人被<a href="Chatroom.html#markChatroomCommonMember"><code>移除普通成员</code></a>时, 所有聊天室成员会收到类型为<a href="ChatroomMessage.html#.attach.type"><code><code>'removeCommon'</code></code></a>的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>。</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>level</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Number</span>


            
            </td>
            
            
                <td class="default">
                
                    0
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>等级</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>custom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>扩展字段, 如果填了, 那么其它聊天室成员收到的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>的<code>attach.custom</code>的值为此字段</p>
<ul>
<li>推荐使用<code>JSON</code>格式构建, 非<code>JSON</code>格式的话, Web端会正常接收, 但是会被其它端丢弃</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>done</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">function</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>结果回调函数</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                        
                    
            </td>
            <td class="description last"></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.markChatroomCommonMember({<br>    account: 'account',<br>    level: 0,<br>    done: markChatroomCommonMemberDone<br>});<br>function markChatroomCommonMemberDone(error) {<br>    console.log('设置聊天室普通成员' + (!error?'成功':'失败'), error);<br>}</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="markChatroomGaglist">
            
            markChatroomGaglist<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/member.js, line 232
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>设置聊天室禁言名单</p>
<ul>
<li>被加入禁言名单的人将不能在该聊天室发送消息</li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>account</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>待设置的账号</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>isAdd</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p><code>true</code>表示添加, <code>false</code>表示移除</p>
<ul>
<li>当有人被<a href="Chatroom.html#markChatroomGaglist"><code>加入禁言名单</code></a>时, 所有聊天室成员会收到类型为<a href="ChatroomMessage.html#.attach.type"><code><code>'gagMember'</code></code></a>的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>。</li>
<li>当有人被<a href="Chatroom.html#markChatroomGaglist"><code>移除禁言名单</code></a>时, 所有聊天室成员会收到类型为<a href="ChatroomMessage.html#.attach.type"><code><code>'ungagMember'</code></code></a>的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>。</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>custom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>扩展字段, 如果填了, 那么其它聊天室成员收到的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>的<code>attach.custom</code>的值为此字段</p>
<ul>
<li>推荐使用<code>JSON</code>格式构建, 非<code>JSON</code>格式的话, Web端会正常接收, 但是会被其它端丢弃</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>done</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">function</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>结果回调函数, 成功时会额外附上<a href="ChatroomMember.html"><code>聊天室成员信息</code></a></p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                        
                    
            </td>
            <td class="description last"></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.markChatroomGaglist({<br>    account: 'account',<br>    isAdd: true,<br>    done: markChatroomGaglistDone<br>});<br>function markChatroomGaglistDone(error, obj) {<br>    console.log('添加聊天室禁言名单' + (!error?'成功':'失败'), error, obj.member);<br>}</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="markChatroomManager">
            
            markChatroomManager<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/member.js, line 134
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>设置聊天室管理员</p>
<ul>
<li>管理员可以<a href="Chatroom.html#markChatroomCommonMember"><code>设置聊天室普通成员</code></a>, <a href="Chatroom.html#markChatroomBlacklist"><code>设置聊天室黑名单</code></a>, <a href="Chatroom.html#markChatroomGaglist"><code>设置聊天室禁言名单</code></a>, <a href="Chatroom.html#kickChatroomMember"><code>踢聊天室成员</code></a></li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>account</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>待设置的账号</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>isAdd</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p><code>true</code>表示添加, <code>false</code>表示移除</p>
<ul>
<li>当有人被<a href="Chatroom.html#markChatroomManager"><code>加为管理员</code></a>时, 所有聊天室成员会收到类型为<a href="ChatroomMessage.html#.attach.type"><code><code>'addManager'</code></code></a>的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>。</li>
<li>当有人被<a href="Chatroom.html#markChatroomManager"><code>移除管理员</code></a>时, 所有聊天室成员会收到类型为<a href="ChatroomMessage.html#.attach.type"><code><code>'removeManager'</code></code></a>的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>。</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>custom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>扩展字段, 如果填了, 那么其它聊天室成员收到的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>的<code>attach.custom</code>的值为此字段</p>
<ul>
<li>推荐使用<code>JSON</code>格式构建, 非<code>JSON</code>格式的话, Web端会正常接收, 但是会被其它端丢弃</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>done</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">function</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>结果回调函数, 成功时会额外附上<a href="ChatroomMember.html"><code>聊天室成员信息</code></a></p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                        
                    
            </td>
            <td class="description last"></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.markChatroomManager({<br>    account: 'account',<br>    isAdd: true,<br>    done: markChatroomManagerDone<br>});<br>function markChatroomManagerDone(error, obj) {<br>    console.log('添加聊天室管理员' + (!error?'成功':'失败'), error, obj.member);<br>}</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="packFileDownloadName">
            
            packFileDownloadName<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{String}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/nos.js, line 1
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>修改图片下载的名字</p>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>url</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>原图 url</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>name</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>下载的名字</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        String
                        
                    
            </td>
            <td class="description last">修改图片下载名字后的图片 url</td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>var url = 'http://nim.nos.netease.com/MTAxMTAwMg==/bmltYV8xNDc5OTNfMTQ0MzE0NTgyNDI0M184YjFkYTMwMS02NjcxLTRiYjktYTUwZC04ZTVlZjZlNzZjMzA=';<br>var nameUrl = chatroom.packFileDownloadName({<br>    url: url,<br>    name: '测试.jpg'<br>});<br>console.log(nameUrl);</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="previewFile">
            
            previewFile<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/msg.js, line 45
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>预览文件</p>
<ul>
<li>开发者可以预览文件, 支持以下几种场景<ul>
<li>通过参数<code>fileInput</code>传入文件选择 dom 节点或者节点 ID, SDK 会读取该节点下的文件, 在上传完成前请不要操作该节点下的文件</li>
<li>通过参数<code>blob</code>传入 Blob 对象</li>
<li>通过参数<code>dataURL</code>传入包含 MIME type 和 base64 数据的 data URL, 此用法需要浏览器支持 Blob</li>
</ul>
</li>
<li>SDK会将文件上传到文件服务器, 然后将拿到的文件对象在<code>done</code>回调中传给开发者, 文件对象有以下几种<ul>
<li><a href="Image.html"><code>图片对象</code></a></li>
<li><a href="Audio.html"><code>音频对象</code></a></li>
<li><a href="Video.html"><code>视频对象</code></a></li>
<li><a href="File.html"><code>文件对象</code></a></li>
</ul>
</li>
<li>开发者在拿到文件对象之后, 可以调用<a href="Chatroom.html#sendFile"><code>发送文件消息</code></a>来发送文件消息。</li>
<li>文件大小限制为最大 100M<ul>
<li>高级浏览器会在上传前就检测文件大小</li>
<li>IE8/IE9 会在上传完成后检测文件大小</li>
</ul>
</li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>type</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>文件过滤器</p>
<ul>
<li>image会过滤掉非图片的文件, audio过滤掉非音频, video会过滤掉非视频的文件</li>
<li>IE8/IE9 不支持文件过滤</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>fileInput</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>
|

<span class="param-type">Node</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>文件选择 dom 节点或者节点 ID, SDK 会读取该节点下的文件, 在上传完成前请不要操作该节点下的文件</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>blob</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Blob</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>Blob 对象</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>dataURL</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>包含 MIME type 和 base64 数据的 data URL</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>uploadprogress</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">uploadprogress</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>上传进度, ie9以下不支持上传进度</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>done</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">done</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>结果回调函数, 成功时会收到文件对象, 请参考</p>
<ul>
<li><a href="Image.html"><code>图片对象</code></a></li>
<li><a href="Audio.html"><code>音频对象</code></a></li>
<li><a href="Video.html"><code>视频对象</code></a></li>
<li><a href="File.html"><code>文件对象</code></a></li>
</ul></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                        
                    
            </td>
            <td class="description last"></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.previewFile({<br>    type: 'image',<br>    fileInput: fileInput,<br>    uploadprogress: function(obj) {<br>        console.log('文件总大小: ' + obj.total + 'bytes');<br>        console.log('已经上传的大小: ' + obj.loaded + 'bytes');<br>        console.log('上传进度: ' + obj.percentage);<br>        console.log('上传进度文本: ' + obj.percentageText);<br>    },<br>    done: function(error, file) {<br>        console.log('上传image' + (!error?'成功':'失败'));<br>        // show file to the user<br>        if (!error) {<br>            var msg = chatroom.sendFile({<br>                scene: 'p2p',<br>                to: 'account',<br>                file: file,<br>                done: sendChatroomMsgDone<br>            });<br>            console.log('正在发送聊天室image消息, id=' + msg.idClient);<br>        }<br>    }<br>});</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="sendCustomMsg">
            
            sendCustomMsg<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Message}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/msg.js, line 197
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>发送自定义消息</p>
<ul>
<li>自定义消息是<a href="ChatroomMessage.html#.type"><code>消息类型</code></a>的一种</li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>content</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>自定义消息的消息内容, 推荐使用JSON格式构建</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>resend</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>是否是重发</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>idClient</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>如果是重发, 那么需要带上之前生成的idClient来标记这条消息</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>custom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>扩展字段</p>
<ul>
<li>推荐使用<code>JSON</code>格式构建, 非<code>JSON</code>格式的话, Web端会正常接收, 但是会被其它端丢弃</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>fromNick</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>发送方的昵称</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>done</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">done</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>结果回调函数</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Message
                        
                    
            </td>
            <td class="description last"><a href="ChatroomMessage.html"><code>消息</code></a></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>var value = Math.ceil(Math.random()*3);<br>var content = {<br>    type: 1,<br>    data: {<br>        value: value<br>    }<br>};<br>var msg = chatroom.sendCustomMsg({<br>    content: JSON.stringify(content),<br>    done: sendChatroomMsgDone<br>});<br>console.log('正在发送聊天室自定义消息, id=' + msg.idClient);</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="sendFile">
            
            sendFile<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void|Message}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/msg.js, line 125
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>发送文件消息</p>
<ul>
<li>文件消息是<a href="ChatroomMessage.html#.type"><code>消息类型</code></a>的一种</li>
<li>开发者可以直接发送文件消息<ul>
<li>支持以下几种场景<ul>
<li>通过参数<code>fileInput</code>传入文件选择 dom 节点或者节点 ID, SDK 会读取该节点下的文件, 在上传完成前请不要操作该节点下的文件</li>
<li>通过参数<code>blob</code>传入 Blob 对象</li>
<li>通过参数<code>dataURL</code>传入包含 MIME type 和 base64 数据的 data URL, 此用法需要浏览器支持 Blob</li>
</ul>
</li>
<li>SDK会先将文件上传到文件服务器, 然后把拿到的文件对象在<code>uploaddone</code>回调中传给用户, 然后将其拼装成文件消息发送出去。</li>
</ul>
</li>
<li>开发者也可以先<a href="Chatroom.html#previewFile"><code>预览文件</code></a>来获取文件对象, 然后调用此接口发送文件消息。<ul>
<li>通过参数<code>file</code>传入文件</li>
</ul>
</li>
<li>直接发送文件消息的话会在<code>beforesend</code>回调里面传入SDK生成的<code>idClient</code>, 如果先预览文件再发送, 那么此接口会直接返回<code>idClient</code></li>
<li>参数<code>type</code>指定了要发送的文件类型, 包括图片、音频、视频和普通文件, 对应的值分别为<code>'image'</code>、<code>'audio'</code>、<code>'video'</code>和<code>'file'</code>, 不传默认为<code>'file'</code>。</li>
<li>图片、音频、视频和普通文件的区别在于具体的文件信息不一样, 具体字段请参考<ul>
<li><a href="Image.html"><code>图片对象</code></a></li>
<li><a href="Audio.html"><code>音频对象</code></a></li>
<li><a href="Video.html"><code>视频对象</code></a></li>
<li><a href="File.html"><code>文件对象</code></a></li>
</ul>
</li>
<li>文件大小限制为最大100M<ul>
<li>高级浏览器会在上传前就检测文件大小</li>
<li>IE8和IE9会在上传完成后检测文件大小</li>
</ul>
</li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		<th>Default</th>
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>type</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>文件过滤器,<br>                                                         <code>'image'</code>会过滤掉非图片的文件, <code>'audio'</code>过滤掉非音频, <code>'video'</code>会过滤掉非视频的文件,<br>                                                         IE8/IE9 不支持文件过滤</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>fileInput</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>
|

<span class="param-type">Node</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>文件选择 dom 节点或者节点 ID, SDK 会读取该节点下的文件, 在上传完成前请不要操作该节点下的文件</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>blob</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Blob</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>Blob 对象</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>dataURL</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>MIME type 和 base64 数据的 data URL</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>file</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Array</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>文件对象, 开发者可以通过<a href="Chatroom.html#previewFile"><code>预览文件</code></a>拿到文件对象</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>wxFilePath</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>仅供微信小程序使用, 通过 wx.chooseImage 或者 wx.startRecord 拿到的临时文件路径</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>resend</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
                <td class="default">
                
                    false
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>是否是重发</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>beginupload</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">function</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>开始上传图片的回调</p>
<ul>
<li>如果开发者传入 fileInput, 在此回调之前不能修改 fileInput</li>
<li>在此回调之后可以取消图片上传, 此回调会接收一个参数 <code>upload</code>, 调用 <code>upload.abort();</code> 来取消文件上传</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>uploadprogress</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">uploadprogress</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>上传进度, IE9以下不支持上传进度</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>uploaddone</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">uploaddone</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>上传完成回调</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>beforesend</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">beforesend</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>发送文件消息之前的回调函数</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>resend</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>是否是重发</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>idClient</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>如果是重发, 那么需要带上之前生成的idClient来标记这条消息</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>custom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>扩展字段</p>
<ul>
<li>推荐使用<code>JSON</code>格式构建, 非<code>JSON</code>格式的话, Web端会正常接收, 但是会被其它端丢弃</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>fromNick</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>发送方的昵称</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>done</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">done</span>


            
            </td>
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>结果回调函数</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                         | 
                    
                        Message
                        
                    
            </td>
            <td class="description last"><ul>
<li>如果提供了参数fileInput, 那么先上传文件到服务器再发送, 不会返回<a href="ChatroomMessage.html"><code>消息</code></a>, 会在beforesend里面返回<a href="ChatroomMessage.html"><code>消息</code></a>.</li>
<li>如果提供了参数file, 那么直接发送文件消息, 返回<a href="ChatroomMessage.html"><code>消息</code></a></li>
</ul></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.sendFile({<br>    type: 'image',<br>    fileInput: fileInput,<br>    uploadprogress: function(obj) {<br>        console.log('文件总大小: ' + obj.total + 'bytes');<br>        console.log('已经上传的大小: ' + obj.loaded + 'bytes');<br>        console.log('上传进度: ' + obj.percentage);<br>        console.log('上传进度文本: ' + obj.percentageText);<br>    },<br>    uploaddone: function(error, file) {<br>        console.log('上传' + (!error?'成功':'失败'), error, file);<br>    },<br>    beforesend: function(msg) {<br>        console.log('正在发送聊天室image消息, id=' + msg.idClient);<br>    },<br>    done: sendChatroomMsgDone<br>});</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="sendGeo">
            
            sendGeo<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Message}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/msg.js, line 230
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>发送地理位置消息</p>
<ul>
<li>地理位置消息是<a href="ChatroomMessage.html#.type"><code>消息类型</code></a>的一种, <code>geo</code>参数请参考<a href="Geo.html"><code>地理位置对象</code></a></li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>geo</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>地理位置对象</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>lng</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Number</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>经度</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>lat</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Number</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>纬度</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>title</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>地址描述</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>resend</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>是否是重发</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>idClient</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>如果是重发, 那么需要带上之前生成的idClient来标记这条消息</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>custom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>扩展字段</p>
<ul>
<li>推荐使用<code>JSON</code>格式构建, 非<code>JSON</code>格式的话, Web端会正常接收, 但是会被其它端丢弃</li>
</ul></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Message
                        
                    
            </td>
            <td class="description last"><a href="ChatroomMessage.html"><code>消息</code></a></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>var msg = chatroom.sendGeo({<br>    scene: 'p2p',<br>    to: 'account',<br>    geo: {<br>        lng: '116.3833',<br>        lat: '39.9167',<br>        title: 'Beijing'<br>    },<br>    done: sendChatroomMsgDone<br>});<br>console.log('正在发送聊天室geo消息, id=' + msg.idClient);</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="sendText">
            
            sendText<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Message}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/msg.js, line 5
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>发送文本消息</p>
<ul>
<li>文本消息是消息的一种, 请参考<a href="ChatroomMessage.html"><code>消息</code></a></li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>text</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>文本消息内容</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>resend</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>是否是重发</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>idClient</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>如果是重发, 那么需要带上之前生成的idClient来标记这条消息</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>custom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>扩展字段</p>
<ul>
<li>推荐使用<code>JSON</code>格式构建, 非<code>JSON</code>格式的话, Web端会正常接收, 但是会被其它端丢弃</li>
</ul></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>done</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">done</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>结果回调函数</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Message
                        
                    
            </td>
            <td class="description last"><a href="ChatroomMessage.html"><code>消息</code></a></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>var msg = chatroom.sendText({<br>    text: 'hello',<br>    done: sendChatroomMsgDone<br>});<br>console.log('正在发送聊天室text消息, id=' + msg.idClient);<br>function sendChatroomMsgDone(error, msg) {<br>    console.log('发送聊天室' + msg.type + '消息' + (!error?'成功':'失败') + ', id=' + msg.idClient, error, msg);<br>}</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="sendTipMsg">
            
            sendTipMsg<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Message}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/msg.js, line 263
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>发送提醒消息</p>
<ul>
<li>提醒消息是<a href="ChatroomMessage.html#.type"><code>消息类型</code></a>的一种</li>
<li>提醒消息用于会话内的状态提醒，如进入会话时出现的欢迎消息，或者会话命中敏感词后的提示消息等等.</li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>tip</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>提醒内容</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>resend</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>是否是重发</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>idClient</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>如果是重发, 那么需要带上之前生成的idClient来标记这条消息</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>custom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>扩展字段</p>
<ul>
<li>推荐使用<code>JSON</code>格式构建, 非<code>JSON</code>格式的话, Web端会正常接收, 但是会被其它端丢弃</li>
</ul></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Message
                        
                    
            </td>
            <td class="description last"><a href="ChatroomMessage.html"><code>消息</code></a></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>var msg = chatroom.sendTipMsg({<br>    scene: 'p2p',<br>    to: 'account',<br>    tip: 'tip content',<br>    done: sendChatroomMsgDone<br>});<br>console.log('正在发送聊天室提醒消息, id=' + msg.idClient);</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="setOptions">
            
            setOptions<span class="signature">(options)</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/index.js, line 141
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>更新聊天室配置, 参数格式跟 <a href="Chatroom.html#.getInstance"><code>Chatroom.getInstance</code></a> 保持一致</p>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>token</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>帐号的 token, 用于建立连接</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>// 更新 token 的例子<br>chatroom.setOptions({<br>    token: 'newToken'<br>});</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="updateChatroom">
            
            updateChatroom<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/index.js, line 190
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>更新聊天室信息</p>
<ul>
<li>当<a href="Chatroom.html#updateChatroom"><code>更新聊天室</code></a>时, 所有聊天室成员会收到类型为<a href="ChatroomMessage.html#.type"><code><code>'updateChatroom'</code></code></a>的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>。</li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>chatroom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>待更新的聊天室信息</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>name</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>聊天室名字</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>announcement</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>聊天室公告</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>broadcastUrl</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>直播地址</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>custom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>扩展字段</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>needNotify</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>是否需要下发对应的通知消息</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>custom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>对应的通知消息的扩展字段</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>done</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">function</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>结果回调函数</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                        
                    
            </td>
            <td class="description last"></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.updateChatroom({<br>  chatroom: {<br>    name: 'newName',<br>    announcement: 'newAnnouncement',<br>    broadcastUrl: 'newBroadcastUrl',<br>    custom: 'newCustom',<br>  },<br>  needNotify: true,<br>  custom: 'biu',<br>  done: updateChatroomDone<br>})<br>function updateChatroomDone () {<br>  console.log('更新聊天室信息' + (!error?'成功':'失败'), error, obj);<br>}</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="updateChatroomMemberTempMute">
            
            updateChatroomMemberTempMute<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/member.js, line 311
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>设置聊天室临时禁言</p>
<ul>
<li>当有人被<a href="Chatroom.html#updateChatroomMemberTempMute"><code>设置聊天室临时禁言</code></a>时，所有聊天室成员会收到类型为<a href="ChatroomMessage.html#.type"><code><code>'addTempMute' or 'removeTempMute'</code></code></a>的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>。</li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>account</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>帐号</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>duration</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Number</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>禁言时长，单位秒，传0表示解除禁言</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>needNotify</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>是否需要下发对应的通知消息</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>custom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>对应的通知消息的扩展字段</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                        
                    
            </td>
            <td class="description last"></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.updateChatroomMemberTempMute({<br>  account: 'account',<br>  duration: 60,<br>  needNotify: true,<br>  custom: 'biu',<br>  done: updateChatroomMemberTempMuteDone<br>})<br>function updateChatroomMemberTempMuteDone(error, obj) {<br>  console.log('设置聊天室临时禁言' + (!error?'成功':'失败'), error, obj);<br>}</p></code></pre>
    

    

    
</dd>

        
            
<dt>
    <div class="nameContainer">
        <h4 class="name" id="updateMyChatroomMemberInfo">
            
            updateMyChatroomMemberInfo<span class="signature">(options)</span><span class="glyphicon glyphicon-circle-arrow-right"></span><span class="type-signature returnType">{Void}</span>
        </h4>
    
        
        <!-- <div class="tag-source">
            api/chatroom/member.js, line 8
        </div> -->
        
    </div>

    
</dt>
<dd>
    
    
    <div class="description">
        <p>更新自己在聊天室内的信息</p>
<ul>
<li>当<a href="Chatroom.html#updateMyChatroomMemberInfo"><code>更新自己在聊天室内的信息</code></a>时, 所有聊天室成员会收到类型为<a href="ChatroomMessage.html#.type"><code><code>'updateMemberInfo'</code></code></a>的<a href="ChatroomMessage.html"><code>聊天室通知消息</code></a>。</li>
</ul>
    </div>
    

    
    
    
    
    
        <h5>Params:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                <p>配置参数</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>member</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>待更新的成员信息</p>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>nick</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>聊天室内的昵称</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>avatar</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>聊天室内的头像</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>custom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>第三方扩展字段</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>needNotify</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>是否需要下发对应的通知消息</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>custom</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>对应的通知消息的扩展字段</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>needSave</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                        <span class="optional">optional</span>
                    
                    
                        
                    
                
                <p>可选，默认false，是否支持nick,avator和custom字段的持久化（固定成员有效）</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>done</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">function</span>


            
            </td>
            
            
            
            <td class="description last">
                
                    
                    
                        
                    
                
                <p>结果回调函数</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    


<table class="params">
    <thead>
    <tr>
        
        <th>Type</th>
        <th class="last">Description</th>
    </tr>
    </thead>
    <tbody>
    
        <tr>
            
            <td class="type">
            
                        Void
                        
                    
            </td>
            <td class="description last"></td>
        </tr>
    
    </tbody>
</table>

    
    
    
        <h5>Example:</h5>
        

    
    <pre class="prettyprint"><code><p>chatroom.updateMyChatroomMemberInfo({<br>  member: {<br>    nick: 'newNick',<br>    avatar: 'newAvatar',<br>    custom: 'newCustom',<br>  },<br>  needNotify: true,<br>  needSave: true,<br>  custom: 'biu',<br>  done: updateMyChatroomMemberInfoDone<br>})<br>function updateMyChatroomMemberInfoDone (error, obj) {<br>  console.log('更新自己在聊天室内的信息' + (!error?'成功':'失败'), error, obj);<br>}</p></code></pre>
    

    

    
</dd>

        </dl>
    
    
    
    
    
</article>

</section>  





        

        <!-- <footer>
            Documentation generated by <a target="_blank" href="https://github.com/jsdoc3/jsdoc">JSDoc 3.4.3</a> on Wed Oct 25 2017 11:15:58 GMT+0800 (中国标准时间)
        </footer> -->
    </div>
</div>
<script>prettyPrint();</script>
<script src="scripts/linenumber.js"></script>
<script src="scripts/main.js"></script>
</body>
</html>